package com.smdk.dsminio.controller;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author 神秘的凯
 * @version 1.0
 * @className TestController
 * @date 2020/10/16/016 14:29
 * @Description 描述
 */
@EnableEurekaClient
@RestController
public class TestController {
    @RequestMapping("/hello")
    public String hello(@RequestParam(value = "name", defaultValue = "神秘的凯") String name) {
        return "你好："+name;
    }

   // @Value("${spring.config.test}")
    String test;
    @GetMapping(value = "/config")
    public String config(){
        return test;
    }
}
